@extends('common')
@section('content')
    <table class="table table-bordered table-hover definewidth m10" >
        <thead>
        <tr>
            <th>姓名</th>
            <th>性别</th>
            <th>身份证号</th>
            <th>报名课程</th>
            <th>联系电话</th>
            <th>备注</th>
            <th>操作</th>
        </tr>
        </thead>
        @foreach($enroll_info['data'] as $v)
            <tr>
                <td>{{$v['enr_name']}}</td>
                <td>@if($v['enr_sex']=='1'){{"男"}}@else{{"女"}}@endif</td>
                <td>{{$v['enr_card']}}</td>
                <td>{{$v['cou_name']}}</td>
                <td>{{$v['enr_phone']}}</td>
                <td>{{$v['enr_intro']}}</td>
                <td><a href="{{url('/execu/entrance')}}?card={{$v['enr_card']}}">入学登记</a></td>
            </tr>
        @endforeach
    </table>
    <div class="inline pull-right page">
        {{$enroll_info['total']}} 条记录 {{$enroll_info['current_page']}}/{{$enroll_info['last_page']}} 页
        <a href="{{url('/execu/apply')}}?page=1">第一页</a>
        @if($enroll_info['current_page']>5)
        <a href='{{url('/execu/apply')}}?page={{$num['min']-5}}' >上5页</a>
        @endif
        <a href="{{url('/execu/apply')}}?page={{$enroll_info['current_page']-1<1?1:$enroll_info['current_page']-1}}">上一页</a>
        @for($i=$num['min'];$i<=$num['max'];$i++)
            @if($i ==$enroll_info['current_page'])
                <a href="{{url('/execu/apply')}}?page={{$i}}" class='current'>{{$i}}</a>
            @else
                <a href="{{url('/execu/apply')}}?page={{$i}}">{{$i}}</a>
            @endif
        @endfor
        <a href="{{url('/execu/apply')}}?page={{$enroll_info['current_page']+1>$enroll_info['last_page']?$enroll_info['last_page']:$enroll_info['current_page']+1}}">下一页</a>
        @if($enroll_info['last_page']>5&&$enroll_info['current_page']<=ceil($enroll_info['last_page']/5-1)*5)
        <a href='{{url('/execu/apply')}}?page={{$num['max']+1}}' >下5页</a>
        @endif
        <a href="{{url('/execu/apply')}}?page={{$enroll_info['last_page']}}" >最后一页</a>
    </div>
@stop